package com.deft.design.abstracts.factory.impl;


import com.deft.design.abstracts.factory.IDatabaseAdapter;
import com.deft.design.abstracts.matter.SqlServer;

/**
 * @author zdl
 * @description
 * @date 2022-04-18
 **/
public class SqlServerDatabaseAdapter implements IDatabaseAdapter {

    SqlServer sqlServer = new SqlServer();

    @Override
    public void insert(String str) {
        sqlServer.add(str);
    }

    @Override
    public String selectById(Integer id) {
        return sqlServer.select(id);
    }

    @Override
    public void deleteById(Integer id) {
        sqlServer.del(id);
    }

    @Override
    public void updateById(Integer id, String str) {
        sqlServer.update(id, str);
    }
}
